import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import axios from './utils/request'

// console.log(store);
Vue.config.productionTip = false;
Vue.prototype.$http = axios

import { Button, Cell, CellGroup } from 'vant';  //vant

Vue.use(Button);  //组件全局挂载的方案
Vue.use(Cell);
Vue.use(CellGroup);

Vue.prototype.$bus = new Vue()

// let windowHeight = document.documentElement.scrollHeight;
// Vue.mixin({
//   data() {
//     return {
//       baseColor: "#07c160",
//       windowHeight: windowHeight + 'px'
//     }
//   },
// })




import mixin from './common/mixin'// 全局混入
Vue.mixin(mixin)
Vue.prototype.$bus = new Vue();  //  数据中转



import init from './common/init';//  登录态维护
const app =   new Vue({
  router,
  store,
  render: h => h(App)
})

init().then(res=>{
  app.$mount('#app')
})




